﻿<!--
Majesty of Omega - The next evolution of macro management space strategy

Copyright 2007-2009 André Claaßen

This file is protected by the terms and conditions of the
Microsoft Community License (Ms-CL 1.1), a copy of which should
have been distributed along with this software. If not,
you may find the license information at the following URL:

http://www.microsoft.com/resources/sharedsource/licensingbasics/communitylicense.mspx
-->
<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:Controls="clr-namespace:Majesty_of_Omega.GUI.Controls;assembly=" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d">

<!--         
    S e t u p P a n e l C o n t r o l 
    .................................
    
    The following Style applies to the SetupPanelControl. See Controls\SetupPanelControl.cs
-->
    <Style TargetType="{x:Type Controls:SetupPanelControl}">
	    <Setter Property="Background" Value="{DynamicResource PanelBackgroundBrush}" />
        <Setter Property="TitleBackground" Value="{DynamicResource InfoTitleBackgroundBrush}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type Controls:SetupPanelControl}">                    
                    <Border x:Name="SetupPanelBorder" Style="{DynamicResource PanelBorderStyle}" VerticalAlignment="Stretch" >
                        <Grid>
                            <Grid.RowDefinitions>
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="*"/>
                            </Grid.RowDefinitions>
                            <Border Background="{TemplateBinding TitleBackground}" BorderThickness="0,0,0,2" CornerRadius="0,0,0,0" BorderBrush="#FFFFFFFF" Padding="8,4,8,4" Width="Auto" Height="Auto" >
                                <ContentPresenter TextBlock.TextAlignment="Center" TextElement.Foreground="White" TextElement.FontWeight="Bold" HorizontalAlignment="Stretch"  ContentSource="Header" OpacityMask="#FF000000" />
                            </Border>
                            <Border x:Name="BorderContent" Grid.Row="1" Background="{TemplateBinding Background}" >
                                <ContentPresenter
                                    HorizontalAlignment="Stretch"
                                    VerticalAlignment="Stretch"
                                    RecognizesAccessKey="True"
                                    ContentSource="Content"
                                 />
                            </Border>
                        </Grid>
                    </Border>
                    <ControlTemplate.Triggers>
                        <Trigger Property="Location" Value="Top">
                            <Setter TargetName="SetupPanelBorder" Property="CornerRadius" Value="5,5,0,0" />
                        </Trigger>
                        <Trigger Property="Location" Value="Middle">
                            <Setter TargetName="SetupPanelBorder" Property="CornerRadius" Value="0,0,0,0" />
                        </Trigger>
                        <Trigger Property="Location" Value="Bottom">
                            <Setter TargetName="SetupPanelBorder" Property="CornerRadius" Value="0,0,5,5" />
                        </Trigger>
                        <Trigger Property="Location" Value="Left">
                            <Setter TargetName="SetupPanelBorder" Property="CornerRadius" Value="5,0,0,5" />
                        </Trigger>
                        <Trigger Property="Location" Value="Right">
                            <Setter TargetName="SetupPanelBorder" Property="CornerRadius" Value="0,5,5,0" />
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>


<!--         
    MooTabControl 
    .................................
    
    The following Style applies to the Master of Orion 3 TabControl
-->

    <Style  TargetType="{x:Type Controls:MooTabItem}"> 
        <!--<Setter Property="FontFamily" Value="Tahoma" />
        <Setter Property="FontSize" Value="20" />
        <Setter Property="FontWeight" Value="Bold" />-->
        <Setter Property="FocusVisualStyle" Value="{DynamicResource MooTabItemFocusVisual}"/>
        <Setter Property="Foreground" Value="White"/>
        <Setter Property="Padding" Value="6,1,6,1"/>
        <Setter Property="BorderBrush" Value="White"/>
        <Setter Property="Background" Value="{DynamicResource MooTabBackgroundBrush}"/>
        <Setter Property="HorizontalContentAlignment" Value="Stretch"/>
        <Setter Property="VerticalContentAlignment" Value="Stretch"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type Controls:MooTabItem}">
                    <Grid SnapsToDevicePixels="true" Height="40" Width="250" Margin="0,0,0,-1" >
                        <Path x:Name="PBd_UnSelected" Fill="{DynamicResource PanelButtonBackgroundBrush}" Stretch="Fill" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Width="Auto" Height="Auto" Data="M2.4967333,8.3475942L6.2472218,2.1908489 24.261875,2.2643839 25.761378,4.1886498 25.738136,8.3475434" StrokeThickness="2" Visibility="Visible" Stroke="#FFFFFFFF" />
                        <Path x:Name="PBd_Selected" Fill="{TemplateBinding Background}" Visibility="Hidden"  Stretch="Fill" Stroke="{TemplateBinding BorderBrush}" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Width="Auto" Height="Auto" Data="M2.4967333,8.3475942 L6.2472218,2.1908489 24.261875,2.2643839 25.761378,4.1886498 25.738136,8.3475434" Margin="-1,-0.5,-1.25,-2.333" StrokeThickness="2"/>
                        <ContentPresenter TextBlock.FontWeight="Bold" TextBlock.FontFamily="Tahoma" TextBlock.FontSize="20"  HorizontalAlignment="{Binding Path=HorizontalContentAlignment, RelativeSource={RelativeSource AncestorType={x:Type ItemsControl}}}" x:Name="Content" VerticalAlignment="{Binding Path=VerticalContentAlignment, RelativeSource={RelativeSource AncestorType={x:Type ItemsControl}}}" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" ContentSource="Header" RecognizesAccessKey="True"/>
                    </Grid>
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsMouseOver" Value="true">
                            <Setter Property="Fill" TargetName="PBd_UnSelected" Value="{DynamicResource MooTabItemHotBackground}"/>
                        </Trigger>
                        <Trigger Property="IsSelected" Value="true">
                            <Setter Property="Panel.ZIndex" Value="1"/>
                            <Setter Property="Visibility" Value="Hidden" TargetName="PBd_UnSelected" />
                            <Setter Property="Visibility" Value="Visible" TargetName="PBd_Selected" />
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <SolidColorBrush x:Key="TabControlNormalBorderBrush2" Color="#8C8E94"/>
    <Style TargetType="{x:Type Controls:MooTabControl}">
        <Setter Property="Foreground" Value="#FFFFFFFF"/>
        <Setter Property="Padding" Value="4,4,4,4"/>
        <Setter Property="BorderThickness" Value="2"/>
        <Setter Property="BorderBrush" Value="White"/>
        <Setter Property="Background" Value="{DynamicResource MooTabBackgroundBrush}"/>
        <Setter Property="HorizontalContentAlignment" Value="Center"/>
        <Setter Property="VerticalContentAlignment" Value="Center"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type Controls:MooTabControl}">
                    <Grid ClipToBounds="true" SnapsToDevicePixels="true" KeyboardNavigation.TabNavigation="Local">
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition x:Name="ColumnDefinition0"/>
                            <ColumnDefinition x:Name="ColumnDefinition1" Width="0"/>
                        </Grid.ColumnDefinitions>
                        <Grid.RowDefinitions>
                            <RowDefinition x:Name="RowDefinition0" Height="Auto"/>
                            <RowDefinition x:Name="RowDefinition1" Height="*"/>
                        </Grid.RowDefinitions>
                        <TabPanel Margin="2,2,2,0" x:Name="HeaderPanel" IsItemsHost="true" Panel.ZIndex="1" Grid.Column="0" Grid.Row="0" KeyboardNavigation.TabIndex="1" HorizontalAlignment="Right"/>
                        <Border x:Name="ContentPanel" Grid.Column="0" Grid.Row="1" KeyboardNavigation.DirectionalNavigation="Contained" KeyboardNavigation.TabIndex="2" KeyboardNavigation.TabNavigation="Local" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}">
                            <ContentPresenter Margin="{TemplateBinding Padding}" x:Name="PART_SelectedContentHost" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" ContentSource="SelectedContent"/>
                        </Border>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
</ResourceDictionary>
